
DEBUG = y

KERNELDIR ?= ~/WDC250GBHD/tiny4412/linux-3.5
PWD := $(shell pwd)

ifeq ($(DEBUG), y)
	DEBFLAGS = -O -g -DSCULL_DEBUG
else
	DEBFLAGS = -O2
endif

EXTRA_CFLAGS += $(DEBFLAGS)


	obj-m := scull.o
	scull-objs := main.o

modules:
	$(MAKE) -C $(KERNELDIR) M=$(PWD) modules

clean:
	rm -fr *.o *.ko *.mod.c  *.order *.symvers .*.cmd .tmp_versions
	
	
